#include <CommandTranslate.h>
Inheritance diagram for CommandTranslate:

Public Member Functions | |
| CommandTranslate (TraffEduObject *obj, osg::Vec3 old_position, osg::Vec3 new_position, OSGWindows *osgwind) | |
| bool | execute () |
| bool | unexecute () |
Private Attributes | |
| OSGWindows * | osgwind_ |
| vector< TraffEduObject * > | translatedObjs_ |
| osg::Vec3 | old_position_ |
| osg::Vec3 | new_position_ |
| TraffEduObject * | obj_ |
| int | first_entrance |
Definition at line 7 of file CommandTranslate.h.
|
||||||||||||||||||||
|
A constructor. Initializes osgwind_, old_position_, and new_position_ variables.
Definition at line 2 of file CommandTranslate.cpp. References first_entrance, new_position_, obj_, old_position_, osgwind, osgwind_, and translatedObjs_. |
|
|
do the translation operation.
Implements Command. Definition at line 12 of file CommandTranslate.cpp. References first_entrance, new_position_, and translatedObjs_. |
|
|
undo the translation operation.
Implements Command. Definition at line 24 of file CommandTranslate.cpp. References old_position_, and translatedObjs_. |
|
|
a private variable. It shows how many times is the execute function is called. Definition at line 45 of file CommandTranslate.h. Referenced by CommandTranslate(), and execute(). |
|
|
a private variable. It is initialized with position of the object(s) after the translation operation. Definition at line 33 of file CommandTranslate.h. Referenced by CommandTranslate(), and execute(). |
|
|
a private variable. It is used to hold the translated object. Definition at line 39 of file CommandTranslate.h. Referenced by CommandTranslate(). |
|
|
a private variable. It is initialized with position of the object(s) before the translation operation. Definition at line 27 of file CommandTranslate.h. Referenced by CommandTranslate(), and unexecute(). |
|
|
a private variable. It is initialized with the unique OSGWindows instance. Definition at line 15 of file CommandTranslate.h. Referenced by CommandTranslate(). |
|
|
a private vector of TraffEduObjects. It holds the translated objects. Definition at line 21 of file CommandTranslate.h. Referenced by CommandTranslate(), execute(), and unexecute(). |
1.4.6-NO